Timer Application using PyQt5 您所在的位置:网站首页 python3 pyqt5 timer Timer Application using PyQt5

Timer Application using PyQt5

#Timer Application using PyQt5| 来源: 网络整理| 查看: 265

GUI Implementation steps : 1. Create a push button to open pop up for getting time and set its geometry 2. Create label to show time and complete status 3. Set label geometry, font size and align its text to center 4. Create three push button for starting the timer, pausing the timer and for resetting the timer 5. Set the geometry of each button Back-end Implementation steps : 1. Create count variable and flag to know if counter is stopped or running 2. Add action to each button 3. Inside the get second button action get the value of second using input dialog box and make the flag false 4. Inside the start action make flag true but if count is zero make if false 5. Inside pause action make flag false 6. Inside the reset action make flag false, set count value to zero and set text to the label 7. Make a timer object which calls its method after every 100 milliseconds 8. Inside the timer action check for the flag then decrement the value of count and set text to the label



【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

    专题文章
      CopyRight 2018-2019 实验室设备网 版权所有